package com.seal.commons.config.apollo.configuration;

import lombok.Data;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.context.properties.ConfigurationProperties;

import java.util.ArrayList;
import java.util.List;



@ConfigurationProperties(prefix = ApolloProperties.APOLLO_PROPERTIES_PREFIX)
@ConditionalOnProperty(prefix = ApolloProperties.APOLLO_PROPERTIES_PREFIX, name = ApolloProperties.META_SERVER_ADDR)
@Data
public class ApolloProperties {

    public static final String APOLLO_PROPERTIES_PREFIX = "spring.seal.apollo.config";

    public static final String META_SERVER_ADDR = "meta-server-addr";

    private String appId = "";

    private String env = "dev";

    private String configService = "";

    private List<String> namespaces = new ArrayList<>();

}
